package com.zhongjinkang.rhythm

import android.annotation.SuppressLint
import android.app.Application
import android.content.Context
import com.huang.mylibrary.db.DBHelper
import com.zhongjinkang.rhythm.Utils.AppManagementUtil
import com.zhongjinkang.rhythm.Utils.SPHelper
import okhttp3.internal.Internal
import okhttp3.internal.Internal.instance


class MyApplication : Application() {


    companion object {
        @SuppressLint("StaticFieldLeak")
//         var context: Context? = null
        var instance: MyApplication? = null
    }


    val appManagementUtil: AppManagementUtil by lazy {
        AppManagementUtil()
    }
    override fun onCreate() {
        super.onCreate()
        SPHelper.init(this)
        SPHelper.instance?.saveToken("Bearerapp eyJhbGciOiJIUzUxMiJ9.eyJzdWIiOiJDVVNUT01FUiIsImF1dGhvcml0aWVzIjo1NTQ0MzY3MTM1OTk4NjQ4MzIsInVzZWRJZCI6NTY5NjMxNDc1Njc2MDkwMzY4fQ.Y5fgGebFNrya0ggvCNlcBkpwDD2KBPtTZTkxNpPx6VY3xLW3465-r2yte-rhJxOC9PQOydQrViI5aDVS1HibHg")
        instance = this
        DBHelper.init(this)
    }


}